<template>
  <a-drawer
    title="产品型号"
    width="80%"
    :visible="visible"
    @close="onClose"
    :destroyOnClose="true"
  >
    <pro-model ref="proModel"/>
  </a-drawer>
</template>

<script>
import proModel from './index'

export default {
  components: {
    proModel
  },
  data() {
    return {
      visible: false
    }
  },
  methods: {
    open(queryParam) {
      this.visible = true
      this.$nextTick(() => {
        this.$refs.proModel.search(queryParam)
      })
    },
    onClose () {
      this.$emit('ok')
      this.visible = false
    }
  }
}
</script>

<style scoped>

</style>
